cmake_minimum_required(VERSION 3.10)
set(projectName Prog2_3_errorChecking)#工程名字
message(STATUS "camke:" ${projectName})
project(${projectName})
SET(EXECUTABLE_OUTPUT_PATH ${CMAKE_RUNTIME_OUTPUT_DIRECTORY})
file(GLOB_RECURSE contain_sources *.cpp *.hpp *.h)
add_executable(${projectName} ${contain_sources})


target_include_directories(${projectName} PUBLIC .
                                   ${DEPS_DIR}/glew/include
                                   ${DEPS_DIR}/glm
                                   ${DEPS_DIR}/SOIL2-1.31
                                   ${DEPS_DIR}/glfw/include
                                   )
#target_link_directories(${projectName} PUBLIC ${DEPS_LIB})
target_link_libraries(${projectName} PUBLIC
${DEPS_DIR}/lib/glfw3.lib
${DEPS_DIR}/lib/glfw3dll.lib
${DEPS_DIR}/lib/glew.lib#cpp first #define GLEW_STATIC  _imp glewInit
${DEPS_DIR}/lib/soil2.lib
OpenGL32#__imp__glClear
)

#add_custom_command(TARGET ${TARGET_NAME} POST_BUILD
#    COMMAND ${CMAKE_COMMAND} -E copy
#    ${BUILD_3RD_DEPS_DIR}/renderdoc/renderdoc.dll ${EXECUTABLE_OUTPUT_PATH}/renderdoc.dll
#)

source_group(TREE ${CMAKE_CURRENT_SOURCE_DIR} FILES ${contain_sources})
message(STATUS "CMAKE_CURRENT_SOURCE_DIR:" ${CMAKE_CURRENT_SOURCE_DIR})
